Skip to contentSkip to conversation

compare images builds settings

DISCUSSION [email protected] 3 participants 3 messages Dec 21, 2024 – Dec 22, 2024

lore
Share & tools
lore
#0 lore raw

Hello, I am new to yocto/openembedded and after following some tutorials I try to achieve my first custom build. The goal is to generate a poky(kirkstone) distro featuring mono on raspberry pi 3B+ I succeed using the meta-mono layer and generated the core-image-mono without any problem.
For learning purpose and avoid depending on an example image, I wanted to generate the core-sato image and amend it with core-image-mono in my local.conf.
So I checked inside the meta-mono/recipes-mono/images/core-image-mono.bb and view it was referencing the core-image-sato and the core-image-mono.inc.
In the core-image-mono.inc, I view these two lines:
IMAGE_INSTALL += "mono mono-helloworld tzdata"

So my approach was to retrieve these lines, paste it in my local.conf and change the image from core-image-mono to core-image-sato . By doing this my output image fails to boot and does not have the same size of the core-image-mono
What would be the way to debug this ? I assumed by running a
bitbake -e|grep IMAGE_INSTALL after the two builds and compare them I would see some diffferences, but no difference I succeed by changing the line
IMAGE_INSTALL += "mono mono-helloworld tzdata"
by
IMAGE_INSTALL :append = "mono mono-helloworld tzdata"

I succeed but I do not understand the right way to debug this ?

Thanks a lot for your support

#1 lore raw

olivierperrier via lists.yoctoproject.org <olivierperrier= [email protected]> schrieb am Sa., 21. Dez. 2024, 10:53:

Quoted 13 lines

Hello, I am new to yocto/openembedded and after following some tutorials I try to achieve my first custom build. The goal is to generate a poky(kirkstone) distro featuring mono on raspberry pi 3B+
I succeed using the meta-mono layer and generated the core-image-mono without any problem.
For learning purpose and avoid depending on an example image, I wanted to generate the core-sato image and amend it with core-image-mono in my local.conf.
So I checked inside the meta-mono/recipes-mono/images/core-image-mono.bb and view it was referencing the core-image-sato and the core-image-mono.inc. In the core-image-mono.inc, I view these two lines:
IMAGE_INSTALL += "mono mono-helloworld tzdata"

Quoted 12 lines

So my approach was to retrieve these lines, paste it in my local.conf and change the image from core-image-mono to core-image-sato .
By doing this my output image fails to boot and does not have the same size of the core-image-mono
What would be the way to debug this ? I assumed by running a bitbake -e|grep IMAGE_INSTALL after the two builds and compare them I would see some diffferences, but no difference
I succeed by changing the line
IMAGE_INSTALL += "mono mono-helloworld tzdata"
by
IMAGE_INSTALL :append = "mono mono-helloworld tzdata"

That's the correct solution.

Quoted 3 lines

I succeed but I do not understand the right way to debug this ?

What you write in this e-mail is correct. You do not need to debug it.

What is confusing you are the different operators bitbake supports. The bitbake documentation covers this. But there are also some presentations like this https://m.youtube.com/watch?v=46gTjz1sju4 that explain the details.
Adrian

Quoted 15 lines

Thanks a lot for your support

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group. View/Reply Online (#64473):
https://lists.yoctoproject.org/g/yocto/message/64473
Mute This Topic: https://lists.yoctoproject.org/mt/110227875/4454582
Group Owner: [email protected]
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [ [email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw
In reply to [email protected]

Hi,
as it's stated in the Yocto documentation, you must use : append instead of the += operator if you want to avoid ordering issues. The reason for this is because doing so unconditionally append s to the variable and avoids ordering problems due to the variable being set in image recipes and.bbclass files with operators like ?=. Using :append ensures the operation takes effect.

https://docs.yoctoproject.org/dev-manual/customizing-images.html#customizing-images-using-local-conf

--
Marco Cavallini | KOAN sas
Bergamo - Italia
embedded software engineering
https://KoanSoftware.com